<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include :: header('虾皮卖家商品轨迹信息列表')" />
</head>
<body class="gray-bg">
     <div class="container-div">
        <div class="row">
            <div class="col-sm-12 search-collapse">
                <form id="formId">
                    <div class="select-list">
                        <ul>
                            <li>
                                <label>批次号：</label>
                                <input type="text" name="batchId"/>
                            </li>
                            <li>
                                <label>商品id：</label>
                                <input type="text" name="itemId"/>
                            </li>
                            <li>
                                <label>店铺id：</label>
                                <input type="text" name="shopId"/>
                            </li>
                            <li>
                                <label>店铺名称：</label>
                                <input type="text" name="shopName"/>
                            </li>
                            <li>
                                <label>商品名称：</label>
                                <input type="text" name="itemName"/>
                            </li>
                            <li>
                                <label>库存：</label>
                                <input type="text" name="stock"/>
                            </li>
                            <li>
                                <label>创建时间：</label>
                                <input type="text" name="ctime"/>
                            </li>
                            <li>
                                <label>近30天销量：</label>
                                <input type="text" name="sold"/>
                            </li>
                            <li>
                                <label>品类id：</label>
                                <input type="text" name="catId"/>
                            </li>
                            <li>
                                <label>评论数：</label>
                                <input type="text" name="cmtCount"/>
                            </li>
                            <li>
                                <label>标志：</label>
                                <input type="text" name="flag"/>
                            </li>
                            <li>
                                <label>商品价格：</label>
                                <input type="text" name="price"/>
                            </li>
                            <li>
                                <label>商品人民币价格：</label>
                                <input type="text" name="priceCny"/>
                            </li>
                            <li>
                                <label>商品最低价：</label>
                                <input type="text" name="priceMin"/>
                            </li>
                            <li>
                                <label>商品最高价：</label>
                                <input type="text" name="priceMax"/>
                            </li>
                            <li>
                                <label>商品打折前最低价：</label>
                                <input type="text" name="priceMinBeforeDiscount"/>
                            </li>
                            <li>
                                <label>商品打折前最高价：</label>
                                <input type="text" name="priceMaxBeforeDiscount"/>
                            </li>
                            <li>
                                <label>是否显示藏价：</label>
                                <input type="text" name="hiddenPriceDisplay"/>
                            </li>
                            <li>
                                <label>商品打折前价格：</label>
                                <input type="text" name="priceBeforeDiscount"/>
                            </li>
                            <li>
                                <label>是否有最低价担保：</label>
                                <input type="text" name="hasLowestPriceGuarantee"/>
                            </li>
                            <li>
                                <label>展示折扣率：</label>
                                <input type="text" name="showDiscount"/>
                            </li>
                            <li>
                                <label>折扣率：</label>
                                <input type="text" name="rawDiscount"/>
                            </li>
                            <li>
                                <label>折扣：</label>
                                <input type="text" name="discount"/>
                            </li>
                            <li>
                                <label>站点：</label>
                                <input type="text" name="country"/>
                            </li>
                            <li>
                                <label>数据创建日期：</label>
                                <input type="text" class="time-input" placeholder="请选择数据创建日期" name="createDate"/>
                            </li>
                            <li>
                                <label>历史销量：</label>
                                <input type="text" name="historicalSold"/>
                            </li>
                            <li>
                                <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
                                <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
                            </li>
                        </ul>
                    </div>
                </form>
            </div>

            <div class="btn-group-sm" id="toolbar" role="group">
                <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="seller:SellerItemInfo:add">
                    <i class="fa fa-plus"></i> 添加
                </a>
                <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="seller:SellerItemInfo:edit">
                    <i class="fa fa-edit"></i> 修改
                </a>
                <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="seller:SellerItemInfo:remove">
                    <i class="fa fa-remove"></i> 删除
                </a>
                <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="seller:SellerItemInfo:export">
                    <i class="fa fa-download"></i> 导出
                </a>
            </div>
            <div class="col-sm-12 select-table table-striped">
                <table id="bootstrap-table"></table>
            </div>
        </div>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var editFlag = [[${@permission.hasPermi('seller:SellerItemInfo:edit')}]];
        var removeFlag = [[${@permission.hasPermi('seller:SellerItemInfo:remove')}]];
        var prefix = ctx + "seller/SellerItemInfo";

        $(function() {
            var options = {
                url: prefix + "/list",
                createUrl: prefix + "/add",
                updateUrl: prefix + "/edit/{id}",
                removeUrl: prefix + "/remove",
                exportUrl: prefix + "/export",
                modalName: "虾皮卖家商品轨迹信息",
                columns: [{
                    checkbox: true
                },
                {
                    field: 'infoId',
                    title: '表的id',
                    visible: false
                },
                {
                    field: 'batchId',
                    title: '批次号'
                },
                {
                    field: 'itemId',
                    title: '商品id'
                },
                {
                    field: 'shopId',
                    title: '店铺id'
                },
                {
                    field: 'shopUrl',
                    title: '店铺链接'
                },
                {
                    field: 'shopName',
                    title: '店铺名称'
                },
                {
                    field: 'itemName',
                    title: '商品名称'
                },
                {
                    field: 'stock',
                    title: '库存'
                },
                {
                    field: 'status',
                    title: '状态(猜)'
                },
                {
                    field: 'ctime',
                    title: '创建时间'
                },
                {
                    field: 'sold',
                    title: '近30天销量'
                },
                {
                    field: 'catId',
                    title: '品类id'
                },
                {
                    field: 'brand',
                    title: '品牌'
                },
                {
                    field: 'cmtCount',
                    title: '评论数'
                },
                {
                    field: 'flag',
                    title: '标志'
                },
                {
                    field: 'itemStatus',
                    title: '产品状态'
                },
                {
                    field: 'price',
                    title: '商品价格'
                },
                {
                    field: 'priceCny',
                    title: '商品人民币价格'
                },
                {
                    field: 'priceMin',
                    title: '商品最低价'
                },
                {
                    field: 'priceMax',
                    title: '商品最高价'
                },
                {
                    field: 'priceMinBeforeDiscount',
                    title: '商品打折前最低价'
                },
                {
                    field: 'priceMaxBeforeDiscount',
                    title: '商品打折前最高价'
                },
                {
                    field: 'hiddenPriceDisplay',
                    title: '是否显示藏价'
                },
                {
                    field: 'priceBeforeDiscount',
                    title: '商品打折前价格'
                },
                {
                    field: 'hasLowestPriceGuarantee',
                    title: '是否有最低价担保'
                },
                {
                    field: 'showDiscount',
                    title: '展示折扣率'
                },
                {
                    field: 'rawDiscount',
                    title: '折扣率'
                },
                {
                    field: 'discount',
                    title: '折扣'
                },
                {
                    field: 'country',
                    title: '站点'
                },
                {
                    field: 'createDate',
                    title: '数据创建日期'
                },
                {
                    field: 'historicalSold',
                    title: '历史销量'
                },
                {
                    title: '操作',
                    align: 'center',
                    formatter: function(value, row, index) {
                        var actions = [];
                        actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.infoId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
                        actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.infoId + '\')"><i class="fa fa-remove"></i>删除</a>');
                        return actions.join('');
                    }
                }]
            };
            $.table.init(options);
        });
    </script>
</body>
</html>